package com.gitee.xhs.sampleMocker;

import com.github.jsonzou.jmockdata.BeanMockerInterceptor;
import com.github.jsonzou.jmockdata.MockConfig;

import java.io.Serializable;

/**
 * @author BigHead
 * @date 2022/7/4 16:59
 * @description AbstractLoopMockerInterceptor
 */
public abstract class AbstractLoopMockerInterceptor<T> implements BeanMockerInterceptor<T>, Serializable {

    private Integer beanNum = 1;

    public synchronized Integer getDataNum(Integer beanNum) {
        if (null != beanNum) {
            this.beanNum = beanNum;
        }
        return this.beanNum;
    }

    /**
     * 生成MockConfig
     * @return MockConfig
     */
    public abstract MockConfig getMockConfig();

}
